<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"      
      xmlns:f="http://xmlns.jcp.org/jsf/core"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:c="http://xmlns.jcp.org/jsp/jstl/core"
      xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
      xmlns:o="http://omnifaces.org/ui"
      xmlns:p="http://primefaces.org/ui">
    <h:body>
        <ui:composition>
            <o:importConstants type="com.satish.gmailapp.constants.WebConstants" />
            <h:form>
                <div>
                    <p:dataList id="messageList" value="#{gmail.messageList}" var="message" type="ordered">
                        <f:facet name="header">
                            <h:outputText value="#{msg.Messages}"/>
                        </f:facet>
                        <h:outputText escape="false"
                                      value="#{gmail.getMessageHeader(message, 'From')}, #{gmail.getMessageHeader(message, 'Subject')}"
                                      style="display:inline-block; #{gmail.isMessageUnread(message) ? 'font-weight: bold' : ''}"/>
                    </p:dataList>
                    <p:blockUI block="dataList" trigger="dataList">
                        <h:outputText value="#{msg.Loading}"/><br />
                    </p:blockUI>
                </div>
            </h:form>
        </ui:composition>
    </h:body>
</html>